package com.zzk.protect.controller;

import com.zzk.protect.common.CommonResult;
import com.zzk.protect.pojo.MedicalItem;
import com.zzk.protect.service.MedicalItemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/medicalItem")
public class MedicalItemController {
    @Autowired
    private MedicalItemService service;
    @GetMapping("/getAll")
    public CommonResult<List<MedicalItem>> getAll(){
        return CommonResult.success(service.list());
    }
}
